function plot_reloc


global clust oldclust a dates1 dates2 cumnums clustratio uniqratio neoratio endratio fieldedit hpp hp
if exist('../tmp/plot_NNK.mat','file')== 2;    load ../tmp/plot_NNK.mat ;end
if size(clust,1) == 0 ;     plot_dendro_0 ; end
hpp=[];a=[];

if exist('pathname','var')==1;if ischar(pathname) == 1
        % affiche infos %%%%%%%%%%%%%%%%
        disp('Plot relative location') ;
        disp('Module plot_reloc  ...')
        
        resizeeffect(fh,bar1)
        clf(fh,'reset');[th,hp,pth]=plot_NNKtools(fh,backcolor,bar1);%a = axes('parent',hp(2),'Layer','top');
        resizeeffect(fh,bar2)
        
        [fieldedit]=timeselector(hp(1),0,19.3/20,1,2/30);
        
        
        uicontrol('Parent',hp(1),'Style','pushbutton','Units','normalized', ...
            'Position',[0 14/20 1/4 1/20], ...
            'CData',geticon('hist'),'TooltipString','Plot the inter-hypocenter distancies', ...
            'Callback','plot_reloc_1(1)');
        uicontrol('Parent',hp(1),'Style','pushbutton','Units','normalized', ...
            'Position',[1/4 14/20 1/4 1/20], ...
            'CData',geticon('rms'),'TooltipString','Plot the RMS', ...
            'Callback','plot_reloc_1(2)');   
        uicontrol('Parent',hp(1),'Style','pushbutton','Units','normalized', ...
            'Position',[2/4 14/20 1/4 1/20], ...
            'CData',geticon('obs'),'TooltipString','Plot the observations', ...
            'Callback','plot_reloc_1(3)');
        %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
        uicontrol('Parent',hp(1),'Style','pushbutton','Units','normalized', ...
            'Position',[0 13/20 1/4 1/20], ...
            'CData',geticon('ploteq'),'TooltipString','Plot the inter-hypocenter distancies', ...
            'Callback','plot_EQ_1(1)');
        
%         uicontrol('Parent',hp(1),'Style','pushbutton','Units','normalized', ...
%             'Position',[2/4 14/20 1/4 1/20], ...
%             'CData',geticon('cumulclust'),'TooltipString','Plot cumulate number of cluster', ...
%             'Callback','plot_dendro_1(2)');
%         %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

        
%         uicontrol('Parent',hp(1),'Style','pushbutton','Units','normalized', ...
%             'Position',[0 13/20 1/4 1/20], ...
%             'CData',geticon('cumuls'),'TooltipString','Plot the cumulate seismicities', ...
%             'Callback','plot_dendro_1(3)');
%         uicontrol('Parent',hp(1),'Style','pushbutton','Units','normalized', ...
%             'Position',[1/4 13/20 1/4 1/20], ...
%             'CData',geticon('derivcumuls'),'TooltipString','Plot the derivates of the cumulate seismicities', ...
%             'Callback','plot_dendro_1(4)');
%         %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%         uicontrol('Parent',hp(1),'Style','pushbutton','Units','normalized', ...
%             'Position',[0 12/20 1/4 1/20], ...
%             'CData',geticon('startNend'),'TooltipString','Plot the cumulate number of starting and ending clusters', ...
%             'Callback','plot_dendro_1(5)');
%         uicontrol('Parent',hp(1),'Style','pushbutton','Units','normalized', ...
%             'Position',[1/4 12/20 1/4 1/20], ...
%             'CData',geticon('startNendderiv'),'TooltipString','Plot the derivates of the cumulate number of starting and ending clusters', ...
%             'Callback','plot_dendro_1(6)');
%         uicontrol('Parent',hp(1),'Style','pushbutton','Units','normalized', ...
%             'Position',[3/4 12/20 1/4 2/20], ...
%             'String','off','TooltipString','Toogle (resampling on & smothing on)|(resampling on & smothing off)|(resampling off & smothing off)', ...
%             'Callback','load ../tmp/plot_NNK.mat;if length(param)<9;param(9)=0;end;param(9)=param(9)+1;if param(9)==3;param(9)=0;end;save ../tmp/plot_NNK.mat param -append');
%         %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%         uicontrol('Parent',hp(1),'Style','pushbutton','Units','normalized', ...
%             'Position',[0 11/20 1/4 1/20], ...
%             'String','R/t','TooltipString','Plot the ratios of repeating earthquake (and unique)', ...
%             'Callback','plot_dendro_1(7)');
%         %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%         uicontrol('Parent',hp(1),'Style','pushbutton','Units','normalized', ...
%             'Position',[0 10/20 1/4 1/20], ...
%             'CData',geticon('clusterwf'),'TooltipString','Pick a cluster on dendrogram and plot waveforms', ...
%             'Callback','dendro2wfs;');
%         uicontrol('Parent',hp(1),'Style','pushbutton','Units','normalized', ...
%             'Position',[1/4 10/20 1/4 1/20], ...
%             'String','T','TooltipString','Take the cluster on dendrogram and make a Taisne model', ...
%             'Callback','dendro2creation;');
%         %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%         uicontrol('Parent',hp(1),'Style','pushbutton','Units','normalized', ...
%             'Position',[0 9/20 1/4 1/20], ...
%             'String','+','TooltipString','plot a GPS .pos file', ...
%             'Callback','plot_GPSinNNK;')
        
        save ../tmp/plot_NNK.mat fieldedit hp h fieldedit a -append
        
        
    else disp('Please choose path before that') ;
    end
else disp('Please choose path before that') ;
end
end